<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <base href="${request.contextPath}/"/>
    <meta name=”renderer” content=”webkit|ie-comp|ie-stand” />
    <meta name="viewport" content="width=device-width, initial-scale=1" />
    <meta http-equiv="content-type" content="text/html; charset=UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <meta name="renderer" content="webkit">
    <link rel="icon" href="favicon.ico">

    <title>政务大厅-在线问答|凌之迅信息|快速开发平台|Learun敏捷开发框架</title>
    <link href="Content/font/css/font-awesome.min.css" rel="stylesheet" />
    <link href="Content/bootstrap/bootstrap.min.css" rel="stylesheet" />

    <link rel="stylesheet" type="text/css" href="Content/webuploader/style.css" />
    <link href="Content/fancybox/jquery.fancybox.css" rel="stylesheet">
    <style>
        textarea{
            margin:0px; width: 720px; height: 100px;
        }
    </style>
      <link href="Content/view/form.css" rel="stylesheet">
    <script src="Content/jquery/jquery-1.10.2.min.js"></script>
    <script src="Content/jquery/jquery.md5.min.js"></script>
    <script src="Content/jquery/plugin/jqprint/jquery.jqprint-0.3.js"></script>
    <script src="Content/laydate/laydate.js"></script>

    <script src="Content/ueditor/ueditor.config.js"></script>
    <script src="Content/ueditor/ueditor.all.min.js"></script>
    <script src="Content/ueditor/lang/zh-cn/zh-cn.js"></script>

    <script src="Content/fancybox/jquery.fancybox.js"></script>
    <script type="text/javascript" src="Content/webuploader/upload.js?version=6.0"></script>
    <script type="text/javascript" src="Content/webuploader/fileupload.js?version=3.9"></script>

    <!--[if lt IE 9]>
    <script src="~/Content/bootstrap/html5shiv.min.js"></script>
    <script src="~/Content/bootstrap/respond.min.js"></script>
    <![endif]-->
    <script>
        var controlUrl = '/pccontrol/home/life/affair';

        $(function () {
            MARK = "false";
            UE.Editor.prototype._bkGetActionUrl = UE.Editor.prototype.getActionUrl;
            UE.Editor.prototype.getActionUrl = function (action) {
                if (action == 'uploadimage') {
                    return "${request.contextPath}/admin/ueditor/uploadUeditor.html?type=image&mark=" + MARK;
                } else if (action == 'uploadfile') {
                    return "${request.contextPath}/admin/ueditor/uploadUeditor.html?type=file";
                } else if (action == 'listimage' || action == 'listfile') {
                    return "${request.contextPath}/admin/ueditor/imageManager.html?picNum=50&insite=false";
                } else if (action == 'uploadvideo') {
                    return "${request.contextPath}/admin/ueditor/uploadUeditor.html?type=media";
                } else if (action == 'catchimage') {
                    return "/jeeadmin/jeecms/ueditor/getRemoteImage.do";
                } else if (action == 'uploadscrawl') {
                    return "/jeeadmin/jeecms/ueditor/scrawlImage.do?Type=Image";
                } else {
                    return this._bkGetActionUrl.call(this, action);
                }
            }
        });


        function request(d) {
            for (var c = location.search.slice(1).split("&"), a = 0; a < c.length; a++) {
                var b = c[a].split("=");
                if (b[0] == d) if ("undefined" == unescape(b[1])) break; else return unescape(b[1])
            }
            return ""
        };
    </script>


</head>

<body class="Firefox 63.0 lr-uitheme-default">
<div id="lr_form_bg" class="lr-form-bg">
</div>
<input type="hidden" id="ywId" value="${id}" class="form-control" />
<input type="hidden" id="id" value="${id}" class="form-control" />

<div class="lr-form-wrap" id="form">
    <div class="col-xs-10 lr-form-item">
        <div><font color="red" face="宋体">重要提示：*使用上传图片功能,禁止修改图片大小格式*</font></div>
    </div>
    <div class="col-xs-12 lr-form-item">
        <div class="lr-form-item-title">提问人姓名<font face="宋体">*</font>
        </div>
        <input id="tname" type="text" class="form-control" isvalid="yes" checkexpession="NotNull"/>
    </div>
    <div class="col-xs-12 lr-form-item">
        <div class="lr-form-item-title">微信名<font face="宋体">*</font>
        </div>
        <input id="nickname" type="text" class="form-control" isvalid="yes" checkexpession="NotNull"/>
    </div>
    <div class="col-xs-12 lr-form-item">
        <div class="lr-form-item-title">联系电话<font face="宋体">*</font>
        </div>
        <input id="tphone" type="text" class="form-control" isvalid="yes" checkexpession="NotNull"/>
    </div>
    <div class="col-xs-12 lr-form-item">
        <div class="lr-form-item-title">住址<font face="宋体">*</font>
        </div>
        <input id="taddress" type="text" class="form-control" isvalid="yes" checkexpession="NotNull"/>
    </div>
    <div class="col-xs-12 lr-form-item">
        <div class="lr-form-item-title">问题<font face="宋体">*</font></div>
        <input id="tcontent" type="text" class="form-control" isvalid="yes" checkexpession="NotNull"/>
    </div>
    <div class="col-xs-12 lr-form-item">
        <div class="lr-form-item-title">客服姓名<font face="宋体">*</font>
        </div>
        <input id="kname" type="text" class="form-control" isvalid="yes" checkexpession="NotNull"/>
    </div>
    <div class="col-xs-12 lr-form-item">
        <div class="lr-form-item-title">客服回复<font face="宋体">*</font></div>
        <div id="content" style="height:270px;" >
            <!--            <img src="" width="365" height="160px" id="content"/>-->
        </div>
    </div>
    <div class="col-xs-12 lr-form-item">
        <div class="lr-form-item-title">客服照片</div>
        <div id="kefu" class="uploader"></div>
        <input type="hidden" id="kefus">
    </div>
</div>


<script>
    //*LaoNa* 上传图片用
    $(document).ready(function(){
        path="";
        $(".fancybox").fancybox({
            openEffect:"none",
            closeEffect:"none",
            helpers: {
                overlay: {
                    locked: false
                }
            }
        });
        $("#kefu").powerWebUpload({ auto: true,fileNum:$("#kefuNum").val(),fileNumLimit:1,type:"image",fileName:"kefu" });
    });

    function upload(){
        var sjlburl = document.getElementsByName("kefu");
        var sjlbls = '';
        for(var i=0;i < sjlburl.length; i++){
            sjlbls += sjlburl[i].value + ",";
        }
        $("#kefus").val(sjlbls);
    }
</script>
<script>
    var parentId = request("parentId");
    var keyValue =$("#id").val();
    var acceptClick;
    var flag;
    var bootstrap = function(a, b) {
        flag = b.frameTab.currentIframe().flag;
        var d = b.frameTab.currentIframe().selectedRow;
        var c = {
            init: function() {
                c.bind();
                c.initData();
            },
            bind: function() {
                e = UE.getEditor("content");
                a("#content")[0].ue = e;


            },
            initData: function() {
                // $(function(){
                //     var ue = UE.getEditor("content");
                //     ue.ready(function() {
                //         //不可编辑
                //         ue.setDisabled();
                //     });
                // });

                if (!!d) {
                    keyValue = d.ywId;
                    a("#form").lrSetFormData(d)
                    e.addListener('ready', function (editor) {

                        e.setContent(d.content)
                    });
                }
                if (flag == "query") {
                    $("#tname").prop("readonly", "readonly");
                    $("#nickname").prop("readonly", "readonly");
                    $("#tphone").prop("readonly", "readonly");
                    $("#taddress").prop("readonly", "readonly");
                    $("#tcontent").prop("readonly", "readonly");
                    $("#kname").prop("readonly", "readonly");
                    // $("#content").prop("readonly", "readonly");
                }

            }
        };
        acceptClick = function(e) {
            if (!a("#form").lrValidform()) {
                return false
            }
            var f = a("#form").lrGetFormData(keyValue);
            f.parentId = parentId;
            a.lrSaveForm(top.$.rootUrl + controlUrl + "/SaveForm?keyValue=" + $("#id").val(), f, function (g) {
                if (!!e) {
                    e()
                }
            })
        };
        c.init()
    };
</script>
<script src="Content/view/uploadInsert.js"></script>
</body>


</html>